<script lang="ts" setup name="DeskConfig">
import { onMounted } from "vue";
import quantity from "@/assets/images/quantity.png";

const props = defineProps<{
  datas: {
    linkName: string; // 文案名字
    linkType: number; // 文案位置
    text: string; // 标题
    linkUrl: string; // 图片地址
    imageList: string[]; // 系统图片地址
    richName: string;
    linkSize: string;
    richSize: number;
    richType: string;
  };
}>();
onMounted(() => {
  console.log(props.datas);
});
</script>

<template>
  <div class="desk-config-box" :style="{ backgroundImage: `url(${datas.linkUrl})` }">
    <!-- <el-image style="width: 100%; height: 720px" :src="datas.linkUrl" alt="" /> -->
    <div class="rich-name" :style="{ fontSize: datas.richSize + 'px', textAlign: datas.richType }">{{ datas.richName }}</div>
    <div class="link-name" :style="{ fontSize: datas.linkSize + 'px', textAlign: datas.linkType }">{{ datas.linkName }}</div>
    <el-image class="img" :src="quantity"></el-image>
  </div>
</template>

<style lang="scss" scoped>
.desk-config-box {
  height: 100%;
  padding-top: 80px;
  color: #ffffff;
  background-color: #797979;
  .rich-name {
    font-size: 15px;
    text-align: center;
  }
  .link-name {
    margin-top: 15px;
  }
  .img {
    display: block;
    width: 340px;
    height: 400px;
    margin: 50px auto;
    border-radius: 5px;
  }
}
</style>
